home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1995 August: Tool Chest / Dev.CD Aug 95 TC / Dev.CD Aug 95 TC.toast / Tool Chest / Interfaces / UniversalInterfaces 2.1B1 / AIncludes / ColorPicker.a < prev    next >
Encoding:
Text File  |  1995-04-18  |  15.2 KB  |  677 lines  |  [TEXT/MPS ]

  1. ;
  2. ;    File:        ColorPicker.a
  3. ;
  4. ;    Contains:    Color Picker package Interfaces.
  5. ;
  6. ;    Version:    Technology:    System 7.5
  7. ;                Package:    Universal Interfaces 2.1ß1 in “MPW Prerelease” on ETO #17
  8. ;
  9. ;    Copyright:    © 1984-1995 by Apple Computer, Inc.
  10. ;                All rights reserved.
  11. ;
  12. ;    Bugs?:        If you find a problem with this file, use the Apple Bug Reporter
  13. ;                stack.  Include the file and version information (from above)
  14. ;                in the problem description and send to:
  15. ;                    Internet:    apple.bugs@applelink.apple.com
  16. ;                    AppleLink:    APPLE.BUGS
  17. ;
  18. ;
  19.  
  20.     IF &TYPE('__COLORPICKER__') = 'UNDEFINED' THEN
  21. __COLORPICKER__ SET 1
  22.  
  23.  
  24.     IF &TYPE('__QUICKDRAW__') = 'UNDEFINED' THEN
  25.     include 'Quickdraw.a'
  26.     ENDIF
  27. ;        include 'Types.a'                                            ;
  28. ;            include 'ConditionalMacros.a'                            ;
  29. ;        include 'MixedMode.a'                                        ;
  30. ;        include 'QuickdrawText.a'                                    ;
  31.  
  32.     IF &TYPE('__MIXEDMODE__') = 'UNDEFINED' THEN
  33.     include 'MixedMode.a'
  34.     ENDIF
  35.  
  36.     IF &TYPE('__WINDOWS__') = 'UNDEFINED' THEN
  37.     include 'Windows.a'
  38.     ENDIF
  39. ;        include 'Memory.a'                                            ;
  40. ;        include 'Events.a'                                            ;
  41. ;            include 'OSUtils.a'                                    ;
  42. ;        include 'Controls.a'                                        ;
  43. ;            include 'Menus.a'                                        ;
  44.  
  45.     IF &TYPE('__DIALOGS__') = 'UNDEFINED' THEN
  46.     include 'Dialogs.a'
  47.     ENDIF
  48. ;        include 'Errors.a'                                            ;
  49. ;        include 'TextEdit.a'                                        ;
  50.  
  51.     IF &TYPE('__CMAPPLICATION__') = 'UNDEFINED' THEN
  52.     include 'CMApplication.a'
  53.     ENDIF
  54. ;        include 'Files.a'                                            ;
  55. ;        include 'Printing.a'                                        ;
  56. ;        include 'CMICCProfile.a'                                    ;
  57.  
  58.     IF &TYPE('__BALLOONS__') = 'UNDEFINED' THEN
  59.     include 'Balloons.a'
  60.     ENDIF
  61.  
  62. ;Maximum small fract value, as long
  63. MaxSmallFract                    EQU        $0000FFFF
  64.  
  65. kDefaultWidth                    EQU        383
  66. kDefaultHeight                    EQU        238
  67.  
  68. kDidNothing                        EQU        0
  69. kColorChanged                    EQU        1
  70. kOkHit                            EQU        2
  71. kCancelHit                        EQU        3
  72. kNewPickerChosen                EQU        4
  73. kApplItemHit                    EQU        5
  74.  
  75. ; typedef short             PickerAction
  76.  
  77. kOriginalColor                    EQU        0
  78. kNewColor                        EQU        1
  79.  
  80. ; typedef short             ColorType
  81.  
  82. kCut                            EQU        0
  83. kCopy                            EQU        1
  84. kPaste                            EQU        2
  85. kClear                            EQU        3
  86. kUndo                            EQU        4
  87.  
  88. ; typedef short             EditOperation
  89.  
  90. kMouseDown                        EQU        0
  91. kKeyDown                        EQU        1
  92. kFieldEntered                    EQU        2
  93. kFieldLeft                        EQU        3
  94. kCutOp                            EQU        4
  95. kCopyOp                            EQU        5
  96. kPasteOp                        EQU        6
  97. kClearOp                        EQU        7
  98. kUndoOp                            EQU        8
  99.  
  100. ; typedef short             ItemModifier
  101.  
  102. kAtSpecifiedOrigin                EQU        0
  103. kDeepestColorScreen                EQU        1
  104. kCenterOnMainScreen                EQU        2
  105.  
  106. ; typedef short             DialogPlacementSpec
  107.  
  108. DialogIsMoveable                EQU        1
  109. DialogIsModal                    EQU        2
  110. CanModifyPalette                EQU        4
  111. CanAnimatePalette                EQU        8
  112. AppIsColorSyncAware                EQU        16
  113. InSystemDialog                    EQU        32
  114. InApplicationDialog                EQU        64
  115. InPickerDialog                    EQU        128
  116. DetachedFromChoices                EQU        256
  117. CanDoColor                        EQU        1
  118. CanDoBlackWhite                    EQU        2
  119. AlwaysModifiesPalette            EQU        4
  120. MayModifyPalette                EQU        8
  121. PickerIsColorSyncAware            EQU        16
  122. CanDoSystemDialog                EQU        32
  123. CanDoApplDialog                    EQU        64
  124. HasOwnDialog                    EQU        128
  125. CanDetach                        EQU        256
  126.  
  127. kNoForcast                        EQU        0
  128. kMenuChoice                        EQU        1
  129. kDialogAccept                    EQU        2
  130. kDialogCancel                    EQU        3
  131. kLeaveFocus                        EQU        4
  132. kPickerSwitch                    EQU        5
  133. kNormalKeyDown                    EQU        6
  134. kNormalMouseDown                EQU        7
  135.  
  136. ; typedef short             EventForcaster
  137. ; A SmallFract value is just the fractional part of a Fixed number,
  138. ;which is the low order word.  SmallFracts are used to save room,
  139. ;and to be compatible with Quickdraw's RGBColor.  They can be
  140. ;assigned directly to and from INTEGERs. 
  141. ; Unsigned fraction between 0 and 1 
  142. ; typedef unsigned short     SmallFract
  143. ; For developmental simplicity in switching between the HLS and HSV
  144. ;models, HLS is reordered into HSL. Thus both models start with
  145. ;hue and saturation values; value/lightness/brightness is last. 
  146. HSVColor                 RECORD    0
  147. hue                         ds.w   1        ; offset: $0 (0)        ;Fraction of circle, red at 0
  148. saturation                 ds.w   1        ; offset: $2 (2)        ;0-1, 0 for gray, 1 for pure color
  149. value                     ds.w   1        ; offset: $4 (4)        ;0-1, 0 for black, 1 for max intensity
  150. sizeof                     EQU *            ; size:   $6 (6)
  151.                         ENDR
  152.  
  153. ; typedef struct HSVColor     HSVColor
  154. HSLColor                 RECORD    0
  155. hue                         ds.w   1        ; offset: $0 (0)        ;Fraction of circle, red at 0
  156. saturation                 ds.w   1        ; offset: $2 (2)        ;0-1, 0 for gray, 1 for pure color
  157. lightness                 ds.w   1        ; offset: $4 (4)        ;0-1, 0 for black, 1 for white
  158. sizeof                     EQU *            ; size:   $6 (6)
  159.                         ENDR
  160.  
  161. ; typedef struct HSLColor     HSLColor
  162. CMYColor                 RECORD    0
  163. cyan                     ds.w   1        ; offset: $0 (0)
  164. magenta                     ds.w   1        ; offset: $2 (2)
  165. yellow                     ds.w   1        ; offset: $4 (4)
  166. sizeof                     EQU *            ; size:   $6 (6)
  167.                         ENDR
  168.  
  169. ; typedef struct CMYColor     CMYColor
  170. PMColor                 RECORD    0
  171. profile                     ds.l   1        ; offset: $0 (0)
  172. color                     ds.l   2        ; offset: $4 (4)
  173. sizeof                     EQU *            ; size:   $C (12)
  174.                         ENDR
  175.  
  176. ; typedef struct PMColor     PMColor, *PMColorPtr
  177. PickerIconData             RECORD    0
  178. scriptCode                 ds.w   1        ; offset: $0 (0)
  179. iconSuiteID                 ds.w   1        ; offset: $2 (2)
  180. helpResType                 ds.l   1        ; offset: $4 (4)
  181. helpResID                 ds.w   1        ; offset: $8 (8)
  182. sizeof                     EQU *            ; size:   $A (10)
  183.                         ENDR
  184.  
  185. ; typedef struct PickerIconData  PickerIconData
  186. PickerInitData             RECORD    0
  187. pickerDialog             ds.l   1        ; offset: $0 (0)
  188. choicesDialog             ds.l   1        ; offset: $4 (4)
  189. flags                     ds.l   1        ; offset: $8 (8)
  190. yourself                 ds.l   1        ; offset: $C (12)
  191. sizeof                     EQU *            ; size:   $10 (16)
  192.                         ENDR
  193.  
  194. ; typedef struct PickerInitData  PickerInitData
  195. PickerMenuItemInfo         RECORD    0
  196. editMenuID                 ds.w   1        ; offset: $0 (0)
  197. cutItem                     ds.w   1        ; offset: $2 (2)
  198. copyItem                 ds.w   1        ; offset: $4 (4)
  199. pasteItem                 ds.w   1        ; offset: $6 (6)
  200. clearItem                 ds.w   1        ; offset: $8 (8)
  201. undoItem                 ds.w   1        ; offset: $A (10)
  202. sizeof                     EQU *            ; size:   $C (12)
  203.                         ENDR
  204.  
  205. ; typedef struct PickerMenuItemInfo  PickerMenuItemInfo
  206. PickerMenuState         RECORD    0
  207. cutEnabled                 ds.b   1        ; offset: $0 (0)
  208. copyEnabled                 ds.b   1        ; offset: $1 (1)
  209. pasteEnabled             ds.b   1        ; offset: $2 (2)
  210. clearEnabled             ds.b   1        ; offset: $3 (3)
  211. undoEnabled                 ds.b   1        ; offset: $4 (4)
  212. undoString                 ds.l   64        ; offset: $5 (5)
  213.                          ORG 262
  214. sizeof                     EQU *            ; size:   $106 (262)
  215.                         ENDR
  216.  
  217. ; typedef struct PickerMenuState  PickerMenuState
  218. ColorPickerInfo         RECORD    0
  219. theColor                 ds     PMColor    ; offset: $0 (0)
  220. dstProfile                 ds.l   1        ; offset: $C (12)
  221. flags                     ds.l   1        ; offset: $10 (16)
  222. placeWhere                 ds.w   1        ; offset: $14 (20)
  223. dialogOrigin             ds     Point    ; offset: $16 (22)
  224. pickerType                 ds.l   1        ; offset: $1A (26)
  225. eventProc                 ds.l   1        ; offset: $1E (30)
  226. colorProc                 ds.l   1        ; offset: $22 (34)
  227. colorProcData             ds.l   1        ; offset: $26 (38)
  228. prompt                     ds.l   64        ; offset: $2A (42)
  229. mInfo                     ds     PickerMenuItemInfo ; offset: $12A (298)
  230. newColorChosen             ds.b   1        ; offset: $136 (310)
  231. filler                     ds.b   1        ; offset: $137 (311)
  232. sizeof                     EQU *            ; size:   $138 (312)
  233.                         ENDR
  234.  
  235. ; typedef struct ColorPickerInfo  ColorPickerInfo
  236. SystemDialogInfo         RECORD    0
  237. flags                     ds.l   1        ; offset: $0 (0)
  238. pickerType                 ds.l   1        ; offset: $4 (4)
  239. placeWhere                 ds.w   1        ; offset: $8 (8)
  240. dialogOrigin             ds     Point    ; offset: $A (10)
  241. mInfo                     ds     PickerMenuItemInfo ; offset: $E (14)
  242. sizeof                     EQU *            ; size:   $1A (26)
  243.                         ENDR
  244.  
  245. ; typedef struct SystemDialogInfo  SystemDialogInfo
  246. PickerDialogInfo         RECORD    0
  247. flags                     ds.l   1        ; offset: $0 (0)
  248. pickerType                 ds.l   1        ; offset: $4 (4)
  249. dialogOrigin             ds.l   1        ; offset: $8 (8)
  250. mInfo                     ds     PickerMenuItemInfo ; offset: $C (12)
  251. sizeof                     EQU *            ; size:   $18 (24)
  252.                         ENDR
  253.  
  254. ; typedef struct PickerDialogInfo  PickerDialogInfo
  255. ApplicationDialogInfo     RECORD    0
  256. flags                     ds.l   1        ; offset: $0 (0)
  257. pickerType                 ds.l   1        ; offset: $4 (4)
  258. theDialog                 ds.l   1        ; offset: $8 (8)
  259. pickerOrigin             ds     Point    ; offset: $C (12)
  260. mInfo                     ds     PickerMenuItemInfo ; offset: $10 (16)
  261. sizeof                     EQU *            ; size:   $1C (28)
  262.                         ENDR
  263.  
  264. ; typedef struct ApplicationDialogInfo  ApplicationDialogInfo
  265. EventData                 RECORD    0
  266. event                     ds.l   1        ; offset: $0 (0)
  267. action                     ds.w   1        ; offset: $4 (4)
  268. itemHit                     ds.w   1        ; offset: $6 (6)
  269. handled                     ds.b   1        ; offset: $8 (8)
  270. filler                     ds.b   1        ; offset: $9 (9)
  271. colorProc                 ds.l   1        ; offset: $A (10)
  272. colorProcData             ds.l   1        ; offset: $E (14)
  273. forcast                     ds.w   1        ; offset: $12 (18)
  274. sizeof                     EQU *            ; size:   $14 (20)
  275.                         ENDR
  276.  
  277. ; typedef struct EventData     EventData
  278. EditData                 RECORD    0
  279. theEdit                     ds.w   1        ; offset: $0 (0)
  280. action                     ds.w   1        ; offset: $2 (2)
  281. handled                     ds.b   1        ; offset: $4 (4)
  282. filler                     ds.b   1        ; offset: $5 (5)
  283. sizeof                     EQU *            ; size:   $6 (6)
  284.                         ENDR
  285.  
  286. ; typedef struct EditData     EditData
  287. ItemHitData             RECORD    0
  288. itemHit                     ds.w   1        ; offset: $0 (0)
  289. iMod                     ds.w   1        ; offset: $2 (2)
  290. action                     ds.w   1        ; offset: $4 (4)
  291. colorProc                 ds.l   1        ; offset: $6 (6)
  292. colorProcData             ds.l   1        ; offset: $A (10)
  293. where                     ds     Point    ; offset: $E (14)
  294. sizeof                     EQU *            ; size:   $12 (18)
  295.                         ENDR
  296.  
  297. ; typedef struct ItemHitData  ItemHitData
  298. HelpItemInfo             RECORD    0
  299. options                     ds.l   1        ; offset: $0 (0)
  300. tip                         ds     Point    ; offset: $4 (4)
  301. altRect                     ds     Rect    ; offset: $8 (8)
  302. theProc                     ds.w   1        ; offset: $10 (16)
  303. helpVariant                 ds.w   1        ; offset: $12 (18)
  304. helpMessage                 ds.w   129        ; offset: $14 (20)
  305. sizeof                     EQU *            ; size:   $116 (278)
  306.                         ENDR
  307.  
  308. ; typedef struct HelpItemInfo  HelpItemInfo
  309. ;    Below are the color conversion routines.
  310. ;
  311. ; pascal SmallFract Fix2SmallFract(Fixed f)
  312. ;
  313.     IF ¬ GENERATINGCFM THEN
  314.         Macro
  315.         _Fix2SmallFract
  316.             move.w    #$0001,-(sp)
  317.             dc.w     $A82E
  318.         EndM
  319.     ELSE
  320.         IMPORT_CFM_FUNCTION    Fix2SmallFract
  321.     ENDIF
  322.  
  323. ;
  324. ; pascal Fixed SmallFract2Fix(SmallFract s)
  325. ;
  326.     IF ¬ GENERATINGCFM THEN
  327.         Macro
  328.         _SmallFract2Fix
  329.             move.w    #$0002,-(sp)
  330.             dc.w     $A82E
  331.         EndM
  332.     ELSE
  333.         IMPORT_CFM_FUNCTION    SmallFract2Fix
  334.     ENDIF
  335.  
  336. ;
  337. ; pascal void CMY2RGB(const CMYColor *cColor, RGBColor *rColor)
  338. ;
  339.     IF ¬ GENERATINGCFM THEN
  340.         Macro
  341.         _CMY2RGB
  342.             move.w    #$0003,-(sp)
  343.             dc.w     $A82E
  344.         EndM
  345.     ELSE
  346.         IMPORT_CFM_FUNCTION    CMY2RGB
  347.     ENDIF
  348.  
  349. ;
  350. ; pascal void RGB2CMY(const RGBColor *rColor, CMYColor *cColor)
  351. ;
  352.     IF ¬ GENERATINGCFM THEN
  353.         Macro
  354.         _RGB2CMY
  355.             move.w    #$0004,-(sp)
  356.             dc.w     $A82E
  357.         EndM
  358.     ELSE
  359.         IMPORT_CFM_FUNCTION    RGB2CMY
  360.     ENDIF
  361.  
  362. ;
  363. ; pascal void HSL2RGB(const HSLColor *hColor, RGBColor *rColor)
  364. ;
  365.     IF ¬ GENERATINGCFM THEN
  366.         Macro
  367.         _HSL2RGB
  368.             move.w    #$0005,-(sp)
  369.             dc.w     $A82E
  370.         EndM
  371.     ELSE
  372.         IMPORT_CFM_FUNCTION    HSL2RGB
  373.     ENDIF
  374.  
  375. ;
  376. ; pascal void RGB2HSL(const RGBColor *rColor, HSLColor *hColor)
  377. ;
  378.     IF ¬ GENERATINGCFM THEN
  379.         Macro
  380.         _RGB2HSL
  381.             move.w    #$0006,-(sp)
  382.             dc.w     $A82E
  383.         EndM
  384.     ELSE
  385.         IMPORT_CFM_FUNCTION    RGB2HSL
  386.     ENDIF
  387.  
  388. ;
  389. ; pascal void HSV2RGB(const HSVColor *hColor, RGBColor *rColor)
  390. ;
  391.     IF ¬ GENERATINGCFM THEN
  392.         Macro
  393.         _HSV2RGB
  394.             move.w    #$0007,-(sp)
  395.             dc.w     $A82E
  396.         EndM
  397.     ELSE
  398.         IMPORT_CFM_FUNCTION    HSV2RGB
  399.     ENDIF
  400.  
  401. ;
  402. ; pascal void RGB2HSV(const RGBColor *rColor, HSVColor *hColor)
  403. ;
  404.     IF ¬ GENERATINGCFM THEN
  405.         Macro
  406.         _RGB2HSV
  407.             move.w    #$0008,-(sp)
  408.             dc.w     $A82E
  409.         EndM
  410.     ELSE
  411.         IMPORT_CFM_FUNCTION    RGB2HSV
  412.     ENDIF
  413.  
  414. ;    Below brings up the ColorPicker 1.0 Dialog
  415. ;
  416. ; pascal Boolean GetColor(Point where, ConstStr255Param prompt, const RGBColor *inColor, RGBColor *outColor)
  417. ;
  418.     IF ¬ GENERATINGCFM THEN
  419.         Macro
  420.         _GetColor
  421.             move.w    #$0009,-(sp)
  422.             dc.w     $A82E
  423.         EndM
  424.     ELSE
  425.         IMPORT_CFM_FUNCTION    GetColor
  426.     ENDIF
  427.  
  428. ;    Below are the ColorPicker 2.0 routines.
  429. ;
  430. ; pascal OSErr PickColor(ColorPickerInfo *theColorInfo)
  431. ;
  432.     IF ¬ GENERATINGCFM THEN
  433.         Macro
  434.         _PickColor
  435.             move.w    #$0213,-(sp)
  436.             dc.w     $A82E
  437.         EndM
  438.     ELSE
  439.         IMPORT_CFM_FUNCTION    PickColor
  440.     ENDIF
  441.  
  442. ;
  443. ; pascal OSErr AddPickerToDialog(ApplicationDialogInfo *info, picker *thePicker)
  444. ;
  445.     IF ¬ GENERATINGCFM THEN
  446.         Macro
  447.         _AddPickerToDialog
  448.             move.w    #$0414,-(sp)
  449.             dc.w     $A82E
  450.         EndM
  451.     ELSE
  452.         IMPORT_CFM_FUNCTION    AddPickerToDialog
  453.     ENDIF
  454.  
  455. ;
  456. ; pascal OSErr CreateColorDialog(SystemDialogInfo *info, picker *thePicker)
  457. ;
  458.     IF ¬ GENERATINGCFM THEN
  459.         Macro
  460.         _CreateColorDialog
  461.             move.w    #$0415,-(sp)
  462.             dc.w     $A82E
  463.         EndM
  464.     ELSE
  465.         IMPORT_CFM_FUNCTION    CreateColorDialog
  466.     ENDIF
  467.  
  468. ;
  469. ; pascal OSErr CreatePickerDialog(PickerDialogInfo *info, picker *thePicker)
  470. ;
  471.     IF ¬ GENERATINGCFM THEN
  472.         Macro
  473.         _CreatePickerDialog
  474.             move.w    #$0416,-(sp)
  475.             dc.w     $A82E
  476.         EndM
  477.     ELSE
  478.         IMPORT_CFM_FUNCTION    CreatePickerDialog
  479.     ENDIF
  480.  
  481. ;
  482. ; pascal OSErr DisposeColorPicker(picker thePicker)
  483. ;
  484.     IF ¬ GENERATINGCFM THEN
  485.         Macro
  486.         _DisposeColorPicker
  487.             move.w    #$0217,-(sp)
  488.             dc.w     $A82E
  489.         EndM
  490.     ELSE
  491.         IMPORT_CFM_FUNCTION    DisposeColorPicker
  492.     ENDIF
  493.  
  494. ;
  495. ; pascal OSErr GetPickerVisibility(picker thePicker, Boolean *visible)
  496. ;
  497.     IF ¬ GENERATINGCFM THEN
  498.         Macro
  499.         _GetPickerVisibility
  500.             move.w    #$0418,-(sp)
  501.             dc.w     $A82E
  502.         EndM
  503.     ELSE
  504.         IMPORT_CFM_FUNCTION    GetPickerVisibility
  505.     ENDIF
  506.  
  507. ;
  508. ; pascal OSErr SetPickerVisibility(picker thePicker, short visible)
  509. ;
  510.     IF ¬ GENERATINGCFM THEN
  511.         Macro
  512.         _SetPickerVisibility
  513.             move.w    #$0319,-(sp)
  514.             dc.w     $A82E
  515.         EndM
  516.     ELSE
  517.         IMPORT_CFM_FUNCTION    SetPickerVisibility
  518.     ENDIF
  519.  
  520. ;
  521. ; pascal OSErr SetPickerPrompt(picker thePicker, Str255 promptString)
  522. ;
  523.     IF ¬ GENERATINGCFM THEN
  524.         Macro
  525.         _SetPickerPrompt
  526.             move.w    #$041a,-(sp)
  527.             dc.w     $A82E
  528.         EndM
  529.     ELSE
  530.         IMPORT_CFM_FUNCTION    SetPickerPrompt
  531.     ENDIF
  532.  
  533. ;
  534. ; pascal OSErr DoPickerEvent(picker thePicker, EventData *data)
  535. ;
  536.     IF ¬ GENERATINGCFM THEN
  537.         Macro
  538.         _DoPickerEvent
  539.             move.w    #$041b,-(sp)
  540.             dc.w     $A82E
  541.         EndM
  542.     ELSE
  543.         IMPORT_CFM_FUNCTION    DoPickerEvent
  544.     ENDIF
  545.  
  546. ;
  547. ; pascal OSErr DoPickerEdit(picker thePicker, EditData *data)
  548. ;
  549.     IF ¬ GENERATINGCFM THEN
  550.         Macro
  551.         _DoPickerEdit
  552.             move.w    #$041c,-(sp)
  553.             dc.w     $A82E
  554.         EndM
  555.     ELSE
  556.         IMPORT_CFM_FUNCTION    DoPickerEdit
  557.     ENDIF
  558.  
  559. ;
  560. ; pascal OSErr DoPickerDraw(picker thePicker)
  561. ;
  562.     IF ¬ GENERATINGCFM THEN
  563.         Macro
  564.         _DoPickerDraw
  565.             move.w    #$021d,-(sp)
  566.             dc.w     $A82E
  567.         EndM
  568.     ELSE
  569.         IMPORT_CFM_FUNCTION    DoPickerDraw
  570.     ENDIF
  571.  
  572. ;
  573. ; pascal OSErr GetPickerColor(picker thePicker, ColorType whichColor, PMColor *color)
  574. ;
  575.     IF ¬ GENERATINGCFM THEN
  576.         Macro
  577.         _GetPickerColor
  578.             move.w    #$051e,-(sp)
  579.             dc.w     $A82E
  580.         EndM
  581.     ELSE
  582.         IMPORT_CFM_FUNCTION    GetPickerColor
  583.     ENDIF
  584.  
  585. ;
  586. ; pascal OSErr SetPickerColor(picker thePicker, ColorType whichColor, PMColor *color)
  587. ;
  588.     IF ¬ GENERATINGCFM THEN
  589.         Macro
  590.         _SetPickerColor
  591.             move.w    #$051f,-(sp)
  592.             dc.w     $A82E
  593.         EndM
  594.     ELSE
  595.         IMPORT_CFM_FUNCTION    SetPickerColor
  596.     ENDIF
  597.  
  598. ;
  599. ; pascal OSErr GetPickerOrigin(picker thePicker, Point *where)
  600. ;
  601.     IF ¬ GENERATINGCFM THEN
  602.         Macro
  603.         _GetPickerOrigin
  604.             move.w    #$0420,-(sp)
  605.             dc.w     $A82E
  606.         EndM
  607.     ELSE
  608.         IMPORT_CFM_FUNCTION    GetPickerOrigin
  609.     ENDIF
  610.  
  611. ;
  612. ; pascal OSErr SetPickerOrigin(picker thePicker, Point where)
  613. ;
  614.     IF ¬ GENERATINGCFM THEN
  615.         Macro
  616.         _SetPickerOrigin
  617.             move.w    #$0421,-(sp)
  618.             dc.w     $A82E
  619.         EndM
  620.     ELSE
  621.         IMPORT_CFM_FUNCTION    SetPickerOrigin
  622.     ENDIF
  623.  
  624. ;
  625. ; pascal OSErr GetPickerProfile(picker thePicker, CMProfileHandle *profile)
  626. ;
  627.     IF ¬ GENERATINGCFM THEN
  628.         Macro
  629.         _GetPickerProfile
  630.             move.w    #$0422,-(sp)
  631.             dc.w     $A82E
  632.         EndM
  633.     ELSE
  634.         IMPORT_CFM_FUNCTION    GetPickerProfile
  635.     ENDIF
  636.  
  637. ;
  638. ; pascal OSErr SetPickerProfile(picker thePicker, CMProfileHandle profile)
  639. ;
  640.     IF ¬ GENERATINGCFM THEN
  641.         Macro
  642.         _SetPickerProfile
  643.             move.w    #$0423,-(sp)
  644.             dc.w     $A82E
  645.         EndM
  646.     ELSE
  647.         IMPORT_CFM_FUNCTION    SetPickerProfile
  648.     ENDIF
  649.  
  650. ;
  651. ; pascal OSErr GetPickerEditMenuState(picker thePicker, PickerMenuState *mState)
  652. ;
  653.     IF ¬ GENERATINGCFM THEN
  654.         Macro
  655.         _GetPickerEditMenuState
  656.             move.w    #$0424,-(sp)
  657.             dc.w     $A82E
  658.         EndM
  659.     ELSE
  660.         IMPORT_CFM_FUNCTION    GetPickerEditMenuState
  661.     ENDIF
  662.  
  663. ;
  664. ; pascal OSErr ExtractPickerHelpItem(picker thePicker, short itemNo, short whichState, HelpItemInfo *helpInfo)
  665. ;
  666.     IF ¬ GENERATINGCFM THEN
  667.         Macro
  668.         _ExtractPickerHelpItem
  669.             move.w    #$0625,-(sp)
  670.             dc.w     $A82E
  671.         EndM
  672.     ELSE
  673.         IMPORT_CFM_FUNCTION    ExtractPickerHelpItem
  674.     ENDIF
  675.  
  676.     ENDIF ; __COLORPICKER__
  677.